package org.example.JVM.ByteCode.Type.CONSTANT;

import org.example.JVM.ByteCode.Type.CpInfo;
import org.example.JVM.ByteCode.Type.U1;
import org.example.JVM.ByteCode.Type.U2;

import java.nio.ByteBuffer;

/**
 * @description:方法类型
 * @author: farprt
 * @create: 2022-11-13 15:58
 **/
public class CONSTANT_MethodType_info extends CpInfo {

    //指向常量池C_Utf8_info结构
    private U2 descriptor_index;

    public CONSTANT_MethodType_info(U1 tag) {
        super(tag);
    }

    @Override
    public void read(ByteBuffer codeBuf) throws Exception {
        descriptor_index = new U2(codeBuf.get(), codeBuf.get());

    }
}